package com.api.oa.services.impl;

import com.api.oa.mapper.OrgClassifyMapper;
import com.api.oa.model.entity.OaOrgClassify;
import com.api.oa.services.IOaOrgClassifyService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;


@Service
public class OaOrgClassifyServiceImpl implements IOaOrgClassifyService {

    @Autowired
    private OrgClassifyMapper orgClassifyMapper;


    @Override
    public Integer add(OaOrgClassify oaOrg) {
        return orgClassifyMapper.insert(oaOrg);
    }

    @Override
    public void remove(Long id) {
        orgClassifyMapper.delete(id);
    }

    @Override
    public Integer update(OaOrgClassify org) {
        return orgClassifyMapper.update(org);
    }

    @Override
    public List<OaOrgClassify> list(Long pid) {
        return orgClassifyMapper.list(pid);
    }

    @Override
    public OaOrgClassify one(Long id) {
        return orgClassifyMapper.findOne(id);
    }
}
